/**
 * 
 */
package de.kuaile.wx.req;

import org.apache.commons.httpclient.NameValuePair;

import de.kuaile.wx.httpclient.AbstractRequest;
import de.kuaile.wx.httpclient.IWXRequest;
import de.kuaile.wx.res.LoginRes;

/**
 * @author Csen
 *
 */
public class LoginReq extends AbstractRequest implements IWXRequest<LoginRes> {
	@Override
	public String  getReferer(){
		return "https://mp.weixin.qq.com/cgi-bin/loginpage?t=wxm2-login&lang=zh_CN";
	}

	public void setUsername(String username) {
		super.add("username", username);
	}

	public void setPwd(String pwd) {
		super.add("pwd", pwd);
	}

	@Override
	public String getWXApiUR() {
		return "https://mp.weixin.qq.com/cgi-bin/login?lang=zh_CN";
	}

	@Override
	public NameValuePair[] getParamArray() {
		return super.toArray();
	}

	@Override
	public Class<LoginRes> getResponseClass() {
		return LoginRes.class;
	}

}
